package com.bm.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName ejyy_epidemic
 */
@TableName(value ="ejyy_epidemic")
@Data
public class EjyyEpidemic implements Serializable {
    /**
     * 
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 
     */
    private Long wechatMpUserId;

    /**
     * 
     */
    private Long communityId;

    /**
     * 
     */
    private Long buildingId;

    /**
     * 1 绿色 2 黄色 3 红色
     */
    private Boolean tourCode;

    /**
     * 
     */
    private Double temperature;

    /**
     * 
     */
    private Boolean returnHometown;

    /**
     * 
     */
    private String returnFromProvince;

    /**
     * 
     */
    private String returnFromCity;

    /**
     * 
     */
    private String returnFromDistrict;

    /**
     * 
     */
    private Long createdBy;

    /**
     * 
     */
    private Long createdAt;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        EjyyEpidemic other = (EjyyEpidemic) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getWechatMpUserId() == null ? other.getWechatMpUserId() == null : this.getWechatMpUserId().equals(other.getWechatMpUserId()))
            && (this.getCommunityId() == null ? other.getCommunityId() == null : this.getCommunityId().equals(other.getCommunityId()))
            && (this.getBuildingId() == null ? other.getBuildingId() == null : this.getBuildingId().equals(other.getBuildingId()))
            && (this.getTourCode() == null ? other.getTourCode() == null : this.getTourCode().equals(other.getTourCode()))
            && (this.getTemperature() == null ? other.getTemperature() == null : this.getTemperature().equals(other.getTemperature()))
            && (this.getReturnHometown() == null ? other.getReturnHometown() == null : this.getReturnHometown().equals(other.getReturnHometown()))
            && (this.getReturnFromProvince() == null ? other.getReturnFromProvince() == null : this.getReturnFromProvince().equals(other.getReturnFromProvince()))
            && (this.getReturnFromCity() == null ? other.getReturnFromCity() == null : this.getReturnFromCity().equals(other.getReturnFromCity()))
            && (this.getReturnFromDistrict() == null ? other.getReturnFromDistrict() == null : this.getReturnFromDistrict().equals(other.getReturnFromDistrict()))
            && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
            && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getWechatMpUserId() == null) ? 0 : getWechatMpUserId().hashCode());
        result = prime * result + ((getCommunityId() == null) ? 0 : getCommunityId().hashCode());
        result = prime * result + ((getBuildingId() == null) ? 0 : getBuildingId().hashCode());
        result = prime * result + ((getTourCode() == null) ? 0 : getTourCode().hashCode());
        result = prime * result + ((getTemperature() == null) ? 0 : getTemperature().hashCode());
        result = prime * result + ((getReturnHometown() == null) ? 0 : getReturnHometown().hashCode());
        result = prime * result + ((getReturnFromProvince() == null) ? 0 : getReturnFromProvince().hashCode());
        result = prime * result + ((getReturnFromCity() == null) ? 0 : getReturnFromCity().hashCode());
        result = prime * result + ((getReturnFromDistrict() == null) ? 0 : getReturnFromDistrict().hashCode());
        result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
        result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", wechatMpUserId=").append(wechatMpUserId);
        sb.append(", communityId=").append(communityId);
        sb.append(", buildingId=").append(buildingId);
        sb.append(", tourCode=").append(tourCode);
        sb.append(", temperature=").append(temperature);
        sb.append(", returnHometown=").append(returnHometown);
        sb.append(", returnFromProvince=").append(returnFromProvince);
        sb.append(", returnFromCity=").append(returnFromCity);
        sb.append(", returnFromDistrict=").append(returnFromDistrict);
        sb.append(", createdBy=").append(createdBy);
        sb.append(", createdAt=").append(createdAt);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}